import math


class ParamsError(Exception):
    pass


class HomeWork():
    def add(self, a: int, b: int) -> int:
        """
        加法运算
        """
        try:
            return a + b
        except ValueError as e:
            raise ParamsError('参数异常')
        finally:
            pass

    def subtract(self, a: int, b: int) -> int:
        """
        减法运算
        """
        try:
            return a - b
        except ValueError as e:
            raise ParamsError('参数异常')
        finally:
            pass

    def ride(self, a: int, b: int) -> int:
        """
        乘法运算
        """
        try:
            return a * b
        except ValueError as e:
            raise ParamsError('参数异常')
        finally:
            pass

    def divide(self, a: int, b: int) -> float:
        """
        除法运算
        """
        try:
            return a / b
        except ValueError as e:
            raise ParamsError('参数')
        finally:
            pass

    def double_div(self, a: int, b: int) -> int:
        """
        整除运算
        """
        try:
            return a // b
        except ValueError as e:
            raise ParamsError('参数异常')
        finally:
            pass

    def surplus(self, a: int, b: int) -> float:
        """
        取余运算
        """
        try:
            return a % b
        except ValueError as e:
            raise ParamsError('参数异常')
        finally:
            pass

    def excract(self, a: int):
        """
        开方运算
        """
        try:
            return math.sqrt(a)
        except ValueError as e:
            raise ParamsError('参数异常')
        finally:
            pass


if __name__ == "__main__":
    pass
